const fs = require('fs')
const path = require('path')

const utils = {
  mkdirsSync: (dirname) => {
    if (fs.existsSync(dirname)) {
      return true
    } else {
      if (utils.mkdirsSync(path.dirname(dirname))) {
        fs.mkdirSync(dirname);
        return true
      }
    }
  }
}

module.exports = utils